<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ include file="/WEB-INF/inc/taglib.inc" %>
<%@ include file="/WEB-INF/inc/script.inc" %>
<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
	<base href="${base}">
    <title>中金通 | 产品档次</title>

    <link href="css/bootstrap.min.css" rel="stylesheet">
    <link href="font-awesome/css/font-awesome.css" rel="stylesheet">

	<!-- Data Tables -->
    <link href="css/plugins/dataTables/dataTables.bootstrap.css" rel="stylesheet">
    <link href="css/plugins/dataTables/dataTables.responsive.css" rel="stylesheet">
    <link href="css/plugins/dataTables/dataTables.tableTools.min.css" rel="stylesheet">

    <link href="css/animate.css" rel="stylesheet">
    <link href="css/style.css" rel="stylesheet">

    <link href="css/plugins/datapicker/datepicker3.css" rel="stylesheet">

</head>
<body>
    <div id="wrapper">
    	<!-- 左侧菜单 -->
        <jsp:include page="/WEB-INF/jsp/common/main-menu.jsp"></jsp:include>

        <div id="page-wrapper" class="gray-bg">
        <div class="row border-bottom">
        <!-- 头部工具栏区 -->
        <jsp:include page="/WEB-INF/jsp/common/main-header.jsp"></jsp:include>
        </div>
        <div class="row wrapper border-bottom white-bg page-heading">
             <div class="col-lg-10">
                 <h2>产品管理</h2>
                 <ol class="breadcrumb">
                     <li>
                         <a href="common/platform">Home</a>
                     </li>
                     <li>
                         <a href="product/list">产品管理</a>
                     </li>
                     <li>
                         <a href="product/list">产品列表</a>
                     </li>
                     
                     <li>
                         <a href="product/detail/${product.id}">${product.briefName}</a>
                     </li>
                     <li class="active">
                          <strong>产品档次</strong>
                     </li>
                </ol>
               </div>
            <div class="col-lg-2">

            </div>
        </div>
		
		<div class="row" style="margin-top:10px;">
			<div class="col-md-12">
                 <div class="tabs-container">
                     <ul class="nav nav-tabs">
                        <li >
							<a href="product/list">
								产品列表
							</a>
						</li>
						<li>
							<a href="product/add">
								 新增产品
							</a>
						</li>
						<li class="active">
								<a>
									 产品档次
								</a>
							</li>
                     </ul>
                  	 <div class="tab-content">
                   		<div class="tab-pane active">
                            <div class="panel-body">
                                 <div class="wrapper wrapper-content animated fadeInRight ecommerce">
						            <input type="hidden" id="productId" name="briefName" value="${product.id}" >
						            
						  			<div class="row">
						                <div class="col-lg-12">
						                    <div class="ibox float-e-margins">
						                        <div ><!-- class="ibox-content" -->
						                        	<button id="doAddModel" class="delete btn btn-outline btn-primary" type="button">新增档次</button>
						                            <table id="modelEditable" class="table table-striped table-bordered table-hover">
										                 <thead>
										                     <tr>
										                         <th>档次</th>
										                         <th>认购范围</th>
										                         <th>预期收益</th>
										                         <th>备注</th>
										                         <th style="background-color:white;">操作</th>
										                     </tr>
										                  </thead>
										                  <tbody>
										                  </tbody>
										            </table>
						                        </div>
						                    </div>
						                </div>
						            </div>
						            
						             <!-- update model start -->
												 	<div class="modal inmodal fade" id="updateModel" tabindex="-1" role="dialog"  aria-hidden="true">
						                                <div class="modal-dialog modal-lg"> 
						                                    <div class="modal-content">
						                                        <div class="modal-header">
						                                            <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
						                                            <h4 class="modal-title" id="grade_edit_id">产品档次</h4>
						                                        </div>
						                                        <div class="modal-body">
						                                        <div id="updateBody"></div>
						                                        <form id="gradeForm" class="form-horizontal">
						                                        	<input type="text" style="display:none" name="productId" class="form-control" value="${product.id}">
						                                        	<input type="text" style="display:none" id="gradeId" name="id" class="form-control">
							                                        <div class="form-group">
							                                        	<label class="col-sm-3 control-label">档次</label>
							                                    		<div class="col-sm-8">
							                                    			<input type="text" id="grade" name="grade" class="form-control">
							                                			</div>
							                                		</div>
						                                			<div class="form-group">
						                                				<label class="col-sm-3 control-label"><font color="red">*&nbsp;&nbsp;</font>认购最小金额(万元)</label>
						                                    			<div class="col-sm-8">
						                                    				<input type="text" id="subScopeStart" name="subScopeStart" class="form-control">
						                                				</div>
						                                			</div>
						                                			<div class="form-group">
						                                				<label class="col-sm-3 control-label"><font color="red">*&nbsp;&nbsp;</font>认购最大金额(万元)</label>
						                                    			<div class="col-sm-8">
						                                    				<input type="text" id="subScopeEnd" name="subScopeEnd" class="form-control" >
						                                				</div>
						                                			</div>
						                                			<div class="form-group">
						                                				<label class="col-sm-3 control-label"><font color="red">*&nbsp;&nbsp;</font>预期收益</label>
						                                    			<div class="col-sm-8">
						                                    				<input type="text" id="prospectiveEarnings" name="prospectiveEarnings" class="form-control">
						                                            	</div>
						                                			</div>
						                                			<div class="form-group">
						                                				<label class="col-sm-3 control-label">备注</label>
						                                    			<div class="col-sm-8">
						                                    				<input type="text" id="grade_remark" name="remark" class="form-control">
						                                            	</div>
						                                			</div>
						                                        </form>
						                                        </div>
						                                        <div class="modal-footer">
						                                            <button type="button" class="btn btn-white" data-dismiss="modal">取 消</button>
						                                            <button type="button" id="saveModel" class="btn btn-primary">保 存</button>
						                                        </div>
						                                    </div>
						                                 
						                                </div>
						                            </div> 
						                            <!-- update model end --> 
            
        							</div>
                                </div>
                            </div>
                            
                        </div>
                    </div>
                </div>
		</div>
		
        <!-- 底部版权 -->
        <jsp:include page="/WEB-INF/jsp/common/main-footer.jsp"></jsp:include>

        </div>
        </div>

    <!-- Mainly scripts -->
    <script src="js/jquery-2.1.1.js"></script>
    <script src="js/bootstrap.min.js"></script>
    <script src="js/plugins/metisMenu/jquery.metisMenu.js"></script>
    <script src="js/plugins/slimscroll/jquery.slimscroll.min.js"></script>
    <script src="js/plugins/jeditable/jquery.jeditable.js"></script>
	<script src="js/jquery.serialize-object.min.js" type="text/javascript"></script>
    <!-- Custom and plugin javascript -->
    <script src="js/inspinia.js"></script>
    <script src="js/plugins/pace/pace.min.js"></script>
	<script src="js/plugins/bootbox/bootbox.min.js" type="text/javascript"></script>
	<script src="js/jquery.tmpl.min.js" type="text/javascript"></script>
    <!-- Data picker -->
    <script src="js/plugins/datapicker/bootstrap-datepicker.js"></script>

    <!-- Data Tables -->
    <script src="js/plugins/dataTables/jquery.dataTables.min.js"></script>
    <script src="js/plugins/dataTables/dataTables.bootstrap.js"></script>
    <script src="js/plugins/dataTables/dataTables.responsive.js"></script>
    <script src="js/plugins/dataTables/dataTables.tableTools.min.js"></script>
    
    <!-- 业务 -->
    <script src="js/product/product-grade-module.js"></script>
    <script src="js/product/FormatUtils.js"></script>

    <!-- Page-Level Scripts -->
    <script>
        $(document).ready(function() {
        	ProductGradeModule.init();
        	
            //$('.footable').footable();

            /* $('#date_added').datepicker({
                todayBtn: "linked",
                keyboardNavigation: false,
                forceParse: false,
                calendarWeeks: true,
                autoclose: true
            });

            $('#date_modified').datepicker({
                todayBtn: "linked",
                keyboardNavigation: false,
                forceParse: false,
                calendarWeeks: true,
                autoclose: true
            }); */

        });

    </script>

</body>
</html>